home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Gold Medal Software 3
/
Gold Medal Software - Volume 3 (Gold Medal) (1994).iso
/
prog
/
word.arj
/
FONT.DOC
< prev
next >
Wrap
Text File
|
1993-01-28
|
2KB
|
37 lines
WGT Fonts
~~~~~~~~~
Copyright 1993 Chris Egerter
Version 3.5 of the Wordup Graphics Toolkit allows you to use different
fonts for any text output. Fonts can easily be created or modified by
you using the Sprite Creator. Only the first 128 characters are used.
Each character can be any size you wish (proportional spacing!) and
may be a special graphic design.
The system font has been saved in a sprite file as system.spr.
When you want to create a new font, copy system.spr to a new name, and
modify the new file. The file has all characters in normal text, so
you know which sprites represent each character. (switching them would cause
much confusion). If you don't plan on using certain characters in your program,
simply leave them as they are.
After you have created your font, run the utility called spr2fnt.exe.
This will convert the sprite file into a WGT font file which you can then
load using the wloadfont command.
To use the new font, declare a font variable such as:
wgtfont sans_serif;
Then load it in using wloadfont:
sans_serif=wloadfont("newfont.fnt");
To display text using the new font pass the font to the wouttextxy command:
wouttextxy(10,10,"This is the new font",sans_serif);
WGT Menus can support different fonts as well. To change the font, load it in
using the procedure above, and change the variable menufont:
menufont=sans_serif;
The menu will be shown using your font when it is displayed. Make sure the font
is not too large however, or the all menus will not fit on the screen.